<?php
/* @var $this MemberTransactionHistoryController */
/* @var $model MemberTransactionHistory */
/* @var $form CActiveForm */ 
?>

<div class="form">

    <?php
    $form = $this->beginWidget('CActiveForm', array(
        'id' => 'member-transaction-history-form',
        'enableAjaxValidation' => false,
    ));
    ?>

    <p class="note">Fields with <span class="required">*</span> are required.</p>

    <?php echo $form->errorSummary($model); ?>
    <?php
    foreach (Yii::app()->user->getFlashes() as $key => $message) {
        echo '<div class="flash-' . $key . '">' . $message . "</div>\n";
    }
    ?>
    <div class="row">
        <?php echo $form->labelEx($model, 'member_id'); ?>
        <?php $list = CHtml::listData(Member::model()->findAll("status=:status", array("status" => 1)), 'member_id', 'username');
        echo $form->dropDownList($model, 'member_id', $list);
        ?>
        <?php echo $form->error($model, 'member_id'); ?>
    </div>
  
    <div class="row">
        <?php echo $form->labelEx($model, 'payment_processors_id'); ?>
        <?php $list = CHtml::listData(PaymentProcessor::model()->findAll(), 'payment_processors_id', 'name');
        echo $form->dropDownList($model, 'payment_processors_id', $list, array('empty' => '---Select a Payment Processor---'));
        ?>
        <?php echo $form->error($model, 'payment_processors_id'); ?>
    </div>
   

    <!--
    <div class="row">
        <?php echo $form->labelEx($model, 'transaction_id'); ?>
        <?php echo $form->textField($model, 'transaction_id', array('size' => 10, 'maxlength' => 10)); ?>
        <?php echo $form->error($model, 'transaction_id'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'transaction_date'); ?>
        <?php echo $form->textField($model, 'transaction_date'); ?>
        <?php echo $form->error($model, 'transaction_date'); ?>
    </div>
    -->
    <div class="row">
        <?php echo $form->labelEx($model, 'particulars'); ?>
        <?php echo $form->textField($model, 'particulars', array('size' => 60, 'maxlength' => 512)); ?>
        <?php echo $form->error($model, 'particulars'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'debit'); ?>
        <?php echo $form->textField($model, 'debit'); ?>
        <?php echo $form->error($model, 'debit'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'credit'); ?>
        <?php echo $form->textField($model, 'credit'); ?>
        <?php echo $form->error($model, 'credit'); ?>
    </div>
    
    <div class="row agree">
        <?php echo $form->labelEx($model, 'isDeposit'); ?>
        <?php echo $form->checkBox($model, 'isDeposit', array('size' => 1, 'maxlength' => 1)); ?>
        <?php echo $form->error($model, 'isDeposit'); ?>
    </div>
    
    <div class="row agree">
        <?php echo $form->labelEx($model, 'isVideoEarning'); ?>
        <?php echo $form->checkBox($model, 'isVideoEarning', array('size' => 1, 'maxlength' => 1)); ?>
        <?php echo $form->error($model, 'isVideoEarning'); ?>
    </div>
    
    <div class="row agree">
        <?php echo $form->labelEx($model, 'isReferralEarning'); ?>
        <?php echo $form->checkBox($model, 'isReferralEarning', array('size' => 1, 'maxlength' => 1)); ?>
        <?php echo $form->error($model, 'isReferralEarning'); ?>
    </div>
    
    <div class="row agree">
        <?php echo $form->labelEx($model, 'isCreditPointEarning'); ?>
        <?php echo $form->checkBox($model, 'isCreditPointEarning', array('size' => 1, 'maxlength' => 1)); ?>
        <?php echo $form->error($model, 'isCreditPointEarning'); ?>
    </div>
    
    <div class="row agree">
        <?php echo $form->labelEx($model, 'isWithdraw'); ?>
        <?php echo $form->checkBox($model, 'isWithdraw', array('size' => 1, 'maxlength' => 1)); ?>
        <?php echo $form->error($model, 'isWithdraw'); ?>
    </div>
    
    <!--
    <div class="row">
        <?php echo $form->labelEx($model, 'balance'); ?>
        <?php echo $form->textField($model, 'balance'); ?>
        <?php echo $form->error($model, 'balance'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'create_date'); ?>
        <?php echo $form->textField($model, 'create_date'); ?>
        <?php echo $form->error($model, 'create_date'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'create_by'); ?>
        <?php echo $form->textField($model, 'create_by', array('size' => 10, 'maxlength' => 10)); ?>
        <?php echo $form->error($model, 'create_by'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'update_date'); ?>
        <?php echo $form->textField($model, 'update_date'); ?>
        <?php echo $form->error($model, 'update_date'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'update_by'); ?>
        <?php echo $form->textField($model, 'update_by', array('size' => 10, 'maxlength' => 10)); ?>
        <?php echo $form->error($model, 'update_by'); ?>
    </div>

    <div class="row">
        <?php echo $form->labelEx($model, 'status'); ?>
        <?php echo $form->textField($model, 'status', array('size' => 45, 'maxlength' => 45)); ?>
        <?php echo $form->error($model, 'status'); ?>
    </div>
    -->
    <div class="row buttons">
        <?php echo CHtml::submitButton($model->isNewRecord ? 'Create' : 'Save'); ?>
    </div>

    <?php $this->endWidget(); ?>

</div><!-- form -->